/**
 * Created by huotaol on 2017/5/3.
 */
import React, {Component} from "react";
import PropTypes from "prop-types";
import {View} from "react-native";
import CustomStyle from "../../common/style/CustomStyle";

class BuyCarFilterTabBar extends Component {
    static propTypes = {
        titleList: PropTypes.array,
        renderItem: PropTypes.func,
    };

    // 构造
    constructor(props) {
        super(props);
        // 初始状态
        this.state = {};
    }

    render() {
        return (
            <View style={{
                height: CustomStyle.getActualSizeInVertical(88), flexDirection: 'row',
                borderBottomWidth: 1,
                borderBottomColor: '#ede9dd',
            }}>
                {this.props.titleList.map((item, i) => this.props.renderItem(item, i))}
            </View>
        );
    }
}

export default BuyCarFilterTabBar;

